package helloworld;

import java.io.UnsupportedEncodingException;
import java.nio.charset.Charset;

public class HelloWorld {
	public static void main(String[] args) throws UnsupportedEncodingException {
//		String s = (char) 65313 + "";
		System.out.println(~0);
		Character c = 128;
//		byte number = 2;
		System.out.println(c);
//		for (char b : a.toCharArray()) {
//			System.out.println((int) b);
//			System.out.println(b);
//		}
//		
//		
//		
		for (Byte b : c.toString().getBytes("unicode")) {
			System.out.println(b);
		}
//		
//		System.out.println(bytes2HexString(a.getBytes("unicode")));
//		
//		for (char b : s.toCharArray()) {
//			System.out.println((byte)b);
//		}
//		for (Byte b : s.getBytes()) {
//			System.out.println(b);
//		}

	}
	
	
	public static String bytes2HexString(byte[] b) {
		  String ret = "";
		  for (int i = 0; i < b.length; i++) {
		   String hex = Integer.toHexString(b[ i ] & 0xFF);
		   if (hex.length() == 1) {
		    hex = '0' + hex;
		   }
		   ret += hex.toUpperCase();
		  }
		  return ret;
		}
}
